package edu.sit.bookstore.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.servlet.ModelAndView;

@Controller
public class JspController {
	@GetMapping("/testjsp")
	public ModelAndView index() {
		ModelAndView mv = new ModelAndView();
		mv.addObject("name", "ccl");
		//模版名称，实际的目录为：src/main/webapp/jsp/index.html
		mv.setViewName("main");
		return mv;
	}

}
